//
//  Config.h
//  TianjinBoHai
//
//  Created by 李莹 on 15/1/16.
//  Copyright (c) 2015年 Binky Lee. All rights reserved.
//

#import "UIFont+Device_iPhoneModel.h"
#import <UIKit/UIKit.h>
#import "UserToken.h"
#pragma mark --------log
#define VOTETEXTCOLOR [UIColor colorWithRed:0.47 green:0.47 blue:0.47 alpha:1]
// 颜色
#define kMyColor(r, g, b) [UIColor colorWithRed:(r)/255.0 green:(g)/255.0 blue:(b)/255.0 alpha:1.0]
//通用字号
#define DEF_FontSize_26 [UIFont fontSize:26]
#define DEF_FontSize_18 [UIFont fontSize:18]
#define DEF_FontSize_17 [UIFont fontSize:17]
#define DEF_FontSize_16 [UIFont fontSize:16]
#define DEF_FontSize_15 [UIFont fontSize:15]
#define DEF_FontSize_14 [UIFont fontSize:14]
#define DEF_FontSize_13 [UIFont fontSize:13]
#define DEF_FontSize_12 [UIFont fontSize:12]
#define DEF_FontSize_11 [UIFont fontSize:11]
#define DEF_FontSize_10 [UIFont fontSize:10]
#define DEF_FontSize_9 [UIFont fontSize:9]
#define DEF_FontSize_8 [UIFont fontSize:8]

#define Strong @property (nonatomic, strong)
#define Assign @property (nonatomic, assign)
#define Copy @property (nonatomic, copy)

//显示msg
#define ShowMessage(msg) [self.view makeToast:msg duration:1 position:CSToastPositionCenter]

//屏幕宽高
#define SCREEN_WIDTH [UIScreen mainScreen].bounds.size.width
#define SCREEN_HEIGHT [UIScreen mainScreen].bounds.size.height

#define BOUND_HEIGHT self.bounds.size.height
#define BOUND_WIDTH self.bounds.size.width

//5S宽高比例
#define ScreenBounds [UIScreen mainScreen].bounds
#define WIDTH_5S_SCALE 320.0 * [UIScreen mainScreen].bounds.size.width
#define HEIGHT_5S_SCALE 568.0 * [UIScreen mainScreen].bounds.size.height
#define WIDTH_6_SCALE 375.0 * [UIScreen mainScreen].bounds.size.width
#define HEIGHT_6_SCALE 812.0 * [UIScreen mainScreen].bounds.size.height
//IOS 11(iPhone X)适配
#define Is_Iphone (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPhone)
#define Is_Iphone_X (Is_Iphone && SCREEN_HEIGHT == 812.0)
#define NAVI_HEIGHT (Is_Iphone_X ? 88 : 64)
#define TABBAR_HEIGHT (Is_Iphone_X ? 83 : 49)
#define BOTTOM_HEIGHT (Is_Iphone_X ? 34 : 0)
//有tabbar就用TabbarHeight，没有就用BottomHeight

//弱应用
#define WS(weakSelf)  __weak __typeof(&*self)weakSelf = self;
#define WXAuthorizationSuccess @"wxLoginSuccess"
//获取用户token
#define userToken [[[UserToken alloc]init]getToken]

/**
 * 一般分割线颜色
 */
extern NSString *dividerColor;

/**
 * 字体颜色
 */
extern NSString *textColor3;

/**
 * 字体颜色1
 */
extern NSString *textColor6;

/**
 * 字体颜色
 */
extern NSString *textColor9;

/**
 * 一般背景颜色
 */
extern NSString *bgColor;

/**
 *  文字按钮  白色
 */
extern NSString *whiteColor;

/**
 *  主颜色
 */
extern NSString *mainColor;

/**
 *  文字\按钮  蓝色
 */
extern NSString *blueColor;

/**
 *  分割线  灰色
 */
extern NSString *grayColor;

/**
 *  背景  灰色
 */
extern NSString *grayBGColor;

/**
 *  控件边  灰色
 */
extern NSString *borderColor;

@interface Config : NSObject

UIColor* getColor(NSString * hexColor);

- (BOOL) isBlankString:(NSString *)string;
@end
